from typing import Optional, List


class Solution:
    # def intersection(self, nums1: List[int], nums2: List[int]) -> List[int]:
    #     dp = set()
    #     for i in nums1:
    #         if i in nums2:
    #             dp.add(i)
    #     return list(dp)
    def intersection(self, nums1: List[int], nums2: List[int]) -> List[int]:
        return list(set(nums1) & set(nums2))
